package com.s4j.struts.biz.model;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.OneToOne;
import javax.persistence.Table;

@Entity
@Table(name="BIZ_MG_SPECIFIC")
public class BizMgSpecific {

	private Long specId;
	
	private PatientDoc patient;
	
	private Integer mode;  //起病方式   1急或较急  2缓慢
	
	private String modeTxt;
	
	private Integer course;  //病程	1病程较长  2病程较短
	
	private String courseTxt;
	
	private Integer trait;  //既往史特点	1既往多病  2既往体健少病	 3病后初愈，正气未复
	
	private String traitTxt;
	
	private Integer physique;  //体质特点	1无明显特点  2平素体质偏虚	 3平素体质偏盛
	
	private String physiqueTxt;

	@Id
	@GeneratedValue(strategy=GenerationType.IDENTITY)
	public Long getSpecId() {
		return specId;
	}

	public void setSpecId(Long specId) {
		this.specId = specId;
	}

	@Column(precision=2, nullable=true)
	public Integer getMode() {
		return mode;
	}

	public void setMode(Integer mode) {
		this.mode = mode;
	}

	@Column(length=100, nullable=true)
	public String getModeTxt() {
		return modeTxt;
	}

	public void setModeTxt(String modeTxt) {
		this.modeTxt = modeTxt;
	}

	@Column(precision=2, nullable=true)
	public Integer getCourse() {
		return course;
	}

	public void setCourse(Integer course) {
		this.course = course;
	}

	@Column(length=100, nullable=true)
	public String getCourseTxt() {
		return courseTxt;
	}

	public void setCourseTxt(String courseTxt) {
		this.courseTxt = courseTxt;
	}

	@Column(precision=2, nullable=true)
	public Integer getTrait() {
		return trait;
	}

	public void setTrait(Integer trait) {
		this.trait = trait;
	}

	@Column(length=100, nullable=true)
	public String getTraitTxt() {
		return traitTxt;
	}

	public void setTraitTxt(String traitTxt) {
		this.traitTxt = traitTxt;
	}

	@Column(precision=2, nullable=true)
	public Integer getPhysique() {
		return physique;
	}

	public void setPhysique(Integer physique) {
		this.physique = physique;
	}

	@Column(length=100, nullable=true)
	public String getPhysiqueTxt() {
		return physiqueTxt;
	}

	public void setPhysiqueTxt(String physiqueTxt) {
		this.physiqueTxt = physiqueTxt;
	}

	@OneToOne  
    @JoinColumn(name="patientId",insertable=true,unique=true)
	public PatientDoc getPatient() {
		return patient;
	}

	public void setPatient(PatientDoc patient) {
		this.patient = patient;
	}
}
